package com.fire.feign_cilent.start.rest;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author Mr.Fire
 * @Desc
 * @Date 2021/12/5
 */
@RestController
public class TestController {

    @Autowired
    FeignCilentProxy feignCilentProxy;

    @GetMapping("/getOrder")
    public String orderTest(){
        String order = feignCilentProxy.feignTest();
        System.out.println(order);
        return order;
    }

    @GetMapping("/getOrder2")
    public String orderTest2(){
        for(int i=0;i<15;i++){
            String order = feignCilentProxy.feignTest();
            System.out.println(order);
        }
        return "success";
    }
}
